Improve Fatboy attack angle and give it a longer projectile lifetime #5979
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
An
AttackAngle
of 10 allows 3 weapons to fire only if the target is stationary. An in-game example of weapons not firing because of this would be a galactic colossus moving perpendicular to and towards the Fatboy at long range, which causes the back weapon to not fire. 20 angle is in the middle of the angle limits, so it should more often allow 3 cannons to fire, depending on unit speed/distance. It does solve the example with the GC.fatboy.cant.shoot.mp4
Angle limits math image
Bone yaw + turret yaw + turret yaw range = actual yaw range. Then intersect all the ranges. The `HeadingArcRange` values are greater than the yaw ranges, so they have no effect and I didn't include them in this image.I noticed that while shooting a GC or groundfiring up a tall plateau the projectiles that miss above the target would time out and be unable to hit the ground, so I increased the projectile lifetime significantly.
Setting
SlaveToBody = true
for the weapons makes it automatically turn towards the target atAttackAngle
, just like battleships, but it makes it annoying to micro with how often it would turn + how fragile it is, so I decided against making that change. For now you have to right click the enemy to get the optimal angle.Ideally we could have a rear version of
AttackAngle
that it could choose as a second option, then it would always try for max single target DPS while not constantly turning 160 degrees (5.3x2 seconds) towards the enemy after you order it to retreat. Alternatively we could compute how it needs to turn to hit its target similar to Nomads' Akimbo feature?